package com.example.myproject.client;

public class Module {
	private int modNum;
	private int XLoc;
	private int YLoc;
	private String orientation;
	private String type;
	private String condition;
	private boolean placed;
	
	public
	
	Module(){
		placed = false;
	}
	
	Module(int num, int x, int y, String orient, String modType, String cond){
		modNum = num;
		XLoc = x;
		YLoc = y;
		orientation = orient;
		type = modType;
		placed = false;
		condition = cond;
	}
	
	void setNum(int newNum){
		modNum = newNum;
	}
	int getNum(){
		return modNum;
	}
	
	void setOrient(String newOrient){
		orientation = newOrient;
	}
	
	String getOrient(){
		return orientation;
	}
	
	void setX (int x){
		XLoc = x;
	}
	
	
	int getX(){
		return XLoc;
	}
	
	void setY (int y){
		YLoc = y;
	}
	
	int getY(){
		return YLoc;
	}
	
	String getType(){
		return type;
	}
	
	void setType(String newType){
		type = newType;
	}
	
	String getCond(){
		return condition;
	}
	
	void setCond(String newCond){
		condition = newCond;
	}
	
	void place(){
		placed = true;
	}
	
	String moduleToString()
	{
		String tmp = Integer.toString(getNum()) + "         " + getCond() + "        X: " + Double.toString(getX()) + "  Y: " + Double.toString(getY()) + "  Turns: " + getOrient();
		return tmp;
	}
	
	String allModuleToString()
	{
		String tmp =getType() + "    " +  Integer.toString(getNum()) + "         " + getCond() + "        X: " + Double.toString(getX()) + "  Y: " + Double.toString(getY()) + "  Turns: " + getOrient();
		return tmp;
	}

}
